package com.serviceprovider.business.module.report.services.dao.impl;

//~--- non-JDK imports --------------------------------------------------------

import com.serviceprovider.business.module.report.model.CustomReport;
import com.serviceprovider.business.module.report.services.dao.interfaces.ICustomReportDao;
import com.serviceprovider.business.module.report.services.dao.interfaces.ICustomReportService;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

//~--- JDK imports ------------------------------------------------------------

import java.util.List;

@Service("customReportService")
public class CustomReportServiceImpl implements ICustomReportService {
    @Autowired
    private ICustomReportDao customReportDao;

    @Override
    public List<CustomReport> listByUser(int userId) {
        return customReportDao.listByUser(userId);
    }

    @Override
    public List<CustomReport> listByUser(String emailId) {
        return customReportDao.listByUser(emailId);
    }

    @Override
    public void save(CustomReport newCustomReport) {
        customReportDao.save(newCustomReport);
    }

    @Override
    public void delete(int reportId) {
        customReportDao.delete(reportId);
    }

    @Override
    public CustomReport get(int id) {
        return customReportDao.get(id);
    }
}



